const KoaRouter = require("@koa/router");
const { showAvatar } = require("../controller/user.controller");
const userController = require("../controller/user.controller");
const { verifyUser, encryption } = require("../middleware/user.middleware");

const userRouter = new KoaRouter({ prefix: "/users" });

userRouter.post("/", verifyUser, encryption, userController.create);

// 查看用户头像
userRouter.get('/avatar/:userId', showAvatar)

module.exports = userRouter;
